package com.itheima.factory;

import com.itheima.dao.UserDao;
import com.itheima.dao.impl.UserDaoImpl;

public class InstanceFactory {


    public UserDao instanceUserDaoObject() {
        return new UserDaoImpl();
    }
    public static UserDao instanceStaticUserDaoObject() {
        return new UserDaoImpl();
    }


    public void init() {
        System.out.println("我被创建了");
    }

    public void destroy() {
        System.out.println("我被销毁了");
    }
}
